#include <stdio.h>
#include <pthread.h>
void* thread_func(void*);
int main(void)
{
	pthread_t t1,t2,t3;
	pthread_create(&t1,NULL,thread_func,NULL);
	pthread_create(&t2,NULL,thread_func,NULL);
	pthread_create(&t3,NULL,thread_func,NULL);
	printf("parent thread %lu\n",pthread_self());
	pthread_join(t1,NULL);
	pthread_join(t2,NULL);
	pthread_join(t3,NULL);
	return 0;
}
void* thread_func(void* data)
{
	printf("child thread %lu\n",pthread_self());
	return NULL;
}
